package com.supplychainapi.dao.prod;

import com.supplychainapi.domain.MaterialListSearch;
import com.supplychainapi.model.ScmTbmaterial;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;
@Repository
public interface ScmTbmaterialMapper extends Mapper<ScmTbmaterial> {

    List<ScmTbmaterial> selectByTreeId(@Param("code") String code,@Param("shopGuid") String shopGuid);

    String getMaxCode(@Param("fsShopGUID") String fsShopGUID);

    Integer nameIsExit(@Param("name") String name,@Param("shopGuid") String shopGuid);


    List<ScmTbmaterial> search(@Param("name") String name,@Param("shopGuid") String shopGuid,@Param("page") Integer page,@Param("size") Integer size);


    List<ScmTbmaterial> selectByClass(@Param("fsNodeCode") String fsNodeCode,@Param("fsShopGUID")String fsShopGUID,@Param("page") Integer page,@Param("size") Integer size );


    List<ScmTbmaterial> getAllMaterial(@Param("shopGuid") String shopGuid,@Param("page") Integer page,@Param("size") Integer size);



    List<ScmTbmaterial> pcGetAllMaterial(MaterialListSearch search);


}